﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="register.aspx.cs" Inherits="E1_eMart.WebForm4" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Registration</title>
    <link href="css/style.css" rel="stylesheet">
    
</head>
<body>
    <form id="form1" runat="server">
    <div id="header">
        <div id="logo">
            <a href="index.aspx">
            <img alt="Our Logo" src="images/logo.png" 
                width="153" /></a>
        </div>
        <div class="clear">
        </div>
        <hr />
        <h2>
            Hi! Ready to register with eMart?</h2>
        <p style="font-size: 14px;">
            It&#39;s your typical registration - it&#39;s free and fairly simple to complete.</p>
        <p>
            Already registered or want to make changes to your account?
            <a href="login.aspx">Sign in.</a></p>
    </div>
    <div id="main_body">
        <div id="main_form">
            <p>
                Username:</p>
            <asp:TextBox ID="txtUsername" runat="server" Height="23px" Width="152px"></asp:TextBox>
            &nbsp;<asp:RequiredFieldValidator ID="nameRequiredField" runat="server" 
                ControlToValidate="txtUsername" ErrorMessage="(*)Username required" 
                SetFocusOnError="True"></asp:RequiredFieldValidator>
            <p>
                Password:</p>
            <asp:TextBox ID="txtPassword" runat="server" TextMode="Password" Width="155px"></asp:TextBox>
            &nbsp;<asp:RequiredFieldValidator ID="passRequiredField" runat="server" 
                ControlToValidate="txtPassword" ErrorMessage="(*)Password required" 
                SetFocusOnError="True"></asp:RequiredFieldValidator>
            <p>
                Re-password:</p>
            &nbsp;<asp:TextBox ID="txtRepassword" runat="server" TextMode="Password" 
                Width="156px"></asp:TextBox>
            <asp:CompareValidator ID="CompareValidator1" runat="server" 
                ControlToCompare="txtPassword" ControlToValidate="txtRepassword" 
                ErrorMessage="Passwords do not match" SetFocusOnError="True"></asp:CompareValidator>
            <br />
            <div id="input_fname">
                <p>
                    First Name:</p>
                &nbsp;<asp:TextBox ID="txtFirstName" runat="server" Width="155px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                    ControlToValidate="txtFirstName" ErrorMessage="(*)First name required" 
                    SetFocusOnError="True"></asp:RequiredFieldValidator>
            </div>
            <div id="input_lname">
                <p>
                    Last Name:</p>
                &nbsp;<asp:TextBox ID="txtLastName" runat="server" Width="162px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                    ControlToValidate="txtLastName" ErrorMessage="(*)Last name required" 
                    SetFocusOnError="True"></asp:RequiredFieldValidator>
            </div>
            <p>
                Gender:<asp:DropDownList ID="cbbGender" runat="server">
                    <asp:ListItem Value="Nam">Male</asp:ListItem>
                    <asp:ListItem Value="Nữ">Female</asp:ListItem>
                </asp:DropDownList>
            </p>
            <p>
                Day of Birth:</p>
            &nbsp;<asp:TextBox ID="txtDate" runat="server" Width="59px"></asp:TextBox>
            &nbsp;<asp:TextBox ID="txtMonth" runat="server" Width="68px"></asp:TextBox>
            <asp:TextBox ID="txtYear" runat="server" Width="67px"></asp:TextBox>
            <br />
            <asp:RangeValidator ID="RangeValidator2" runat="server" 
                ControlToValidate="txtDate" ErrorMessage="Invalid date" MaximumValue="31" 
                MinimumValue="1" Type="Integer"></asp:RangeValidator>
            <asp:RangeValidator ID="RangeValidator1" runat="server" 
                ControlToValidate="txtMonth" ErrorMessage="Invalid month" MaximumValue="12" 
                MinimumValue="1" Type="Integer"></asp:RangeValidator>
            <asp:RangeValidator ID="RangeValidator3" runat="server" 
                ControlToValidate="txtYear" ErrorMessage="Invalid year" MaximumValue="2008" 
                MinimumValue="1920" Type="Integer"></asp:RangeValidator>
            <p>
                Birthplace:</p>
            <p>
                <asp:TextBox ID="txtBirthplace" runat="server" Width="164px"></asp:TextBox>
            </p>
            <p>
                Phone number:</p>
            <p>
                <asp:TextBox ID="txtPhone" runat="server" Width="168px"></asp:TextBox>
                <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" 
                    ControlToValidate="txtPhone" ErrorMessage="Phone number invalid" 
                    SetFocusOnError="True" ValidationExpression="\d\d\d\d\d\d\d\d\d\d\d"></asp:RegularExpressionValidator>
            </p>
            <p>
                Email:</p>
            <asp:TextBox ID="txtEmail" runat="server" AutoCompleteType="Email" 
                Width="177px"></asp:TextBox>
            &nbsp;<asp:RegularExpressionValidator ID="RegularExpressionValidator1" 
                runat="server" ControlToValidate="txtEmail" 
                ErrorMessage="Invalid email address" SetFocusOnError="True" 
                ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
            <p>
                Address:</p>
            <p>
                &nbsp;<asp:TextBox ID="txtAddress" runat="server" Width="178px"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" 
                    ControlToValidate="txtAddress" ErrorMessage="(*)Address required"></asp:RequiredFieldValidator>
                <br />
                <br />
                <asp:Label ID="Label1" runat="server" Text="Credit card:"></asp:Label>
                <br />
                <asp:TextBox ID="txtCreditcard" runat="server" Width="178px"></asp:TextBox>
                &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" 
                    ControlToValidate="txtCreditcard" ErrorMessage="(*)Number credit card required"></asp:RequiredFieldValidator>
            </p>
            <p>
                <asp:Image ID="captcha" src="JpegImage.aspx" runat="server"/>
            <br>
             <strong>Enter the code shown above:</strong><br>
				<asp:TextBox id="CodeNumberTextBox" runat="server"></asp:TextBox>             
                <asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" 
                    ControlToValidate="CodeNumberTextBox" ErrorMessage="(*) Captcha required"></asp:RequiredFieldValidator>
            </p>
            <p>
                &nbsp;<asp:CheckBox ID="CbAgree" runat="server" />
                I agree that:
            </p>
            <ul>
                <li>I accept the User Agreement and Privacy Policy.</li>
                <li>I may receive communications from eMart and can change my notification 
                    preferences in My eMart.</li>
                <li>I&#39;m at least 18 years old.</li>
            </ul>
            <asp:Label ID="Label2" runat="server" ForeColor="Red"></asp:Label>
            <br />
            <asp:Button ID="bttSubmit" runat="server" onclick="Button1_Click" 
                Text="Submit"/>
            <asp:Button ID="bttCancel" runat="server" Text="Cancel" />
        </div>
    </div>

<div id="footer">
        <hr />
        <h4> Copyright © 2011 eMart Inc. All rights reserved.</h4>
        <div id="about">
            <a href="about.html"><h3>About</h3></a>
            <a href="about.html"><h3>Contact Us</h3></a>
        </div>
</div>
</form>
</body>
</html>
